package com.lhdx.practical.service.impl;

import com.lhdx.practical.bean.Menu;
import com.lhdx.practical.dao.MenuDao;
import com.lhdx.practical.service.MenuService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service("MenuService")
public class MenuServiceImpl implements MenuService {
    @Autowired
    private MenuDao menuDao;

    @Override
    public List<Menu> findAllByPid(long pid) {
        return menuDao.findAllByPid(pid);
    }

    @Override
    public List<Menu> findAllByIdIn(Long[] ids) {
        return menuDao.findAllByIdIn(ids);
    }

    @Override
    public Menu findById(long id) {
        return menuDao.findById(id);
    }
}
